module.exports = function(window, document) {
	var apivm = require('../../common/avm.min')(window, document);
	var avm = apivm;
	var api = apivm.api;
	var Component = apivm.Component;
	var $ = apivm.$;
	(function() {
	var Com = /*@__PURE__*/ (function(Component) {
		function Com(props) {
			Component.call(this, props);
			this.data = {
				num: 0
			};
		}

		if (Component) Com.__proto__ = Component;
		Com.prototype = Object.create(Component && Component.prototype);
		Com.prototype.constructor = Com;
		Com.prototype.apiready = function() {
			//like created
			console.log("apiready:页面运行环境准备完毕时&渲染完毕");
		};
		Com.prototype.install = function() {
			console.log("install:组件挂载到DOM之前");
		};
		Com.prototype.installed = function() {
			console.log("installed：组件挂载之后");
		};
		Com.prototype.beforeRender = function() {
			console.log("beforeRender：组件渲染之前");
		};
		Com.prototype.uninstall = function() {
			console.log("uninstall:组件移除之前");
		};
		Com.prototype.beforeUpdate = function() {
			console.log("beforeUpdated：组件更新之前");
		};
		Com.prototype.afterUpdate = function() {
			console.log("updated：组件更新之后");
		};
		Com.prototype.add = function() {
			this.data.num++;
		};
		Com.prototype.go = function() {
			api.openWin({
				name: "list",
				url: "../list/list.stml"
			});
		};
		Com.prototype.render = function() {
			return apivm.h(
				"view",
				{class: "page"},
				apivm.h("view", {onClick: this.add}, "点击次数：", this.data.num),
				apivm.h("button", {onClick: this.go}, "跳转")
			);
		};

		return Com;
	})(Component);
	apivm.define("com", Com);
	apivm.render(apivm.h("com", null), "body");
})();

	window['createApp'] = function() {
		apivm.$_start();
	}
	return avm;
}